import React, { Component } from 'react'
//导入connect
import { connect } from 'react-redux'
class ComB extends Component {
  render() {
    console.log(this.props.count, 'ComBProps')
    return (
      <div>
        <h3>{this.props.count}</h3>
      </div>
    )
  }
}
const mapStateToProps = (state) => {
  console.log(state, 'ComB')
  return state
}

export default connect(mapStateToProps)(ComB)
